import Vue from 'vue'
import Router from 'vue-router'
import login from '@/components/login'
import home from '@/components/home'
import user from '@/components/users'
import Welcome from '@/components/Welcome'
Vue.use(Router)
export default new Router({
  routes: [
    {
      path: '/',
      redirect: '/login'
    },
    {
      path: '/login',
      component: login
    },
    {
      path: '/home',
      component: home,
      redirect: '/welcome',
      children: [{ path: '/users', component: user }, { path: '/welcome', component: Welcome }]
    }
  ]
})
